<?php
/**
 * Class Infrastructure_Mapper_Factory
 */
class Infrastructure_Mapper_Factory
{
    /**
     * @var PDO
     */
    protected $pdo;

    /**
     * @return Infrastructure_Mapper_Timelog
     */
    public function createTimeLog()
    {
        static $instance;
        return ($instance)
            ? $instance
            : new Infrastructure_Mapper_Timelog($this->pdo);
    }

    /**
     * @param PDO $pdo
     */
    public function __construct(PDO $pdo)
    {
        $this->pdo = $pdo;
    }
}
